unit Path;

interface
uses
  Classes, QTable;

type
  TPath = class
  private
    FStateList  : TList;
    function GetState(Index: Integer): TState;

    function GetCount: Integer;


  public
    constructor Create;
    function Add (State : TState) : Integer;

    procedure Clear;

    property Count : Integer read GetCount;
    property Items [Index : Integer] : TState read GetState; default;
  end;


implementation

{ TPath }

function TPath.Add(State: TState): Integer;
begin
  Result := FStateList.Add(State);
end;


procedure TPath.Clear;
begin
  FStateList.Clear;
end;

constructor TPath.Create;
begin
  FStateList := TList.Create;
end;


function TPath.GetCount: Integer;
begin
  Result := FStateList.Count;
end;


function TPath.GetState(Index: Integer): TState;
begin
  Result := TState (FStateList[Index]);
end;

end.
